<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<?php $this->load->view('head'); ?>
</head>

<body>
	<?php $this->load->view('header_guest.php'); ?>
	
	<!-- Content Area -->
	<div class="wrapper-world content">
		<div class="wrapper">
			<h1>Sign in</h1>
			
			<div class="right-half">
				<div class="info-box">
					<div class="info-text">
					<p>Have you forgotten your password? We've got you covered! <?php echo anchor('retrieve-password', 'Retrieve password'); ?>.</p>
					<p>No account yet? <?php echo anchor('create-an-account', 'Sign up'); ?>.</p>
					</div>
				</div>
			</div>
			
			<div class="left-half">
				<?php echo form_open('sign-in', array('class' => 'standard-form')); ?>
					<div class="one<?php if (isset($loginError)): ?> warning<?php endif; ?>">
						<?php echo form_label('e-mail', 'email'); ?>
						<?php $emailInput = array('name' => 'email', 'id' => 'email'); ?>
						<?php if (isset($loginError)) {
							$emailInput['value'] = $this->input->post('email');
						} ?>
						<?php if (isset($loginError)): ?>
						<div class="warning-message">Wrong username/password combination.</div>
						<?php endif; ?>
						<div class="type-text"><?php echo form_input($emailInput); ?></div>
						<div class="clr"></div>
					</div>
					<div class="one<?php if (isset($loginError)): ?> warning<?php endif; ?>">
						<?php echo form_label('Password', 'password'); ?>
						<div class="type-text"><?php echo form_password(array('name' => 'password', 'id' => 'password')); ?></div>
						<div class="clr"></div>
					</div>
					<input type="hidden" name="joblogin" value="<?php echo ((!$this->input->post('joblogin')) ? "0" : "1"); ?>" />
					<div class="one no-left">
						<div class="type-btn"><?php echo form_submit('dologin', 'Submit')?></div>
						<div class="clr"></div>
					</div>
				</form>
			</div>
			
			<div class="clr"></div>
		</div>
	</div> <!-- end of wrapper-world and .content -->
	
	
	<div class="wrapper-world footer-top">
		<div class="wrapper"></div>	
	</div>
	
	<?php $this->load->view('footer'); ?>
</body>
</html>
